#ifndef _DHT11_H
#define _DHT11_H

#include "stm32f1xx_hal.h"
#include "tim.h"

#define DHT11_PORT GPIOA
#define DHT11_PIN GPIO_PIN_1
extern I2C_HandleTypeDef hi2c1;
void delay(uint16_t us);

void Set_Pin_Output(GPIO_TypeDef *GPIOx, uint16_t GPIO_Pin);

void Set_Pin_Input(GPIO_TypeDef *GPIOx, uint16_t GPIO_Pin);

void DHT11_Start(void);

uint8_t DHT11_Check_Response(void);

uint8_t DHT11_Read(void);

#endif

